package com.bdqn.t382.sz;

public class ModulusOperation implements Operation {
    @Override
    public double calculate(double num1, double num2) {
        if (num2 == 0) {
            throw new ArithmeticException("除数不能为零");
        }
        return (double) ((int) num1 % (int) num2);
    }
}
